How to create nested function in python

visit shbcf.ru